package xyz.lisys.taglib;

import javax.servlet.jsp.tagext.TagSupport;
import java.io.IOException;

public class HelloTag extends TagSupport {
    private String name;

    @Override
    public int doEndTag() {
        try {
            pageContext.getOut().println("Hello, " + name);
        } catch (IOException e) {
            throw new RuntimeException(e);
        }

        return EVAL_PAGE;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
